import { BaseWindow } from "../../../../component/window/BaseWindow";
import { ILayer } from "../../../../mvc/interfaces/ILayer";
import { Language } from "../../../../../extend/language/Language";
import { GButton } from "../../../../../com/mui/controls/GButton";
import { ObjCreate } from "../../common/ObjCreate";
import { DataEvent } from "../../../events/DataEvent";
import { EventName } from "../../../mvc/EventName";
import { PopupManager } from "../../../manager/PopupManager";
import { GTextFiled } from "../../../../../com/mui/controls/GTextFiled";
//class MountStartBatchResultPanel
    
    export  class MountStartBatchResultPanel extends BaseWindow
    {
        constructor(arg1: ILayer=null)
        {
            super(arg1);
            this.setSize(280, 160);
            this.titleHeight = 26;
            this.title = Language.getString(70235);
            return;
        }

        public get btnOK(): GButton
        {
            return this._btnOK;
        }

        protected /* override */ createDisposedChildrenImpl(): void
        {
            super.createDisposedChildrenImpl();
            ObjCreate.createBg(18, 36, 244, 78, this);
            this._btnOK = ObjCreate.createGButton(Language.getString(69901), 100, 120, 80, 28, this);
            this._btnOK.configEventListener(flash.events.MouseEvent.CLICK, this.onButtonClick);
            this.closeBtn.visible = false;
            this._resultText = ObjCreate.createTextField("", 35, 44, 210, 80, this);
            this._resultText.wordWrap = true;
            this._resultText.multiline = true;
            return;
        }

        public setResultText(arg1: string): void
        {
            this._resultText.htmlText = arg1;
            return;
        }

        protected onButtonClick(arg1: Object /* flash.events.MouseEvent */): void
        {
            this.dispatchEvent(new DataEvent(EventName.MountStartsBantchResultOk));
            PopupManager.removePopup(this);
            return;
        }

        protected /* override */ disposeImpl(arg1: Boolean=true): void
        {
            this._btnOK.dispose(arg1);
            this._resultText.dispose(arg1);
            this._resultText = null;
            super.disposeImpl(arg1);
            return;
        }

        /* internal */ /* var */_btnOK: GButton;

        /* internal */ /* var */_resultText: GTextFiled;
    }
